$(function() {
	var tr = $('.car_search_results .propositions table tr').not(':first');
	tr.bind('mouseover', function() {
		$(this).addClass('hovered');
	});
	tr.bind('mouseout', function() {
		$(this).removeClass('hovered');
	});
	tr.bind('mousedown', function() {
		var $this = $(this);
		var currentPrice = $this.find('td.price b').text();
		$this.parents('table').find('.selected').removeClass('selected');
		$this.parents('table').find('a.tm-radiobutton img').removeClass('checked');
		$this.find('input[type="radio"]').trigger('click').next(0).find('img').addClass('checked');
		$this.addClass('selected');
		$this.removeClass('hovered');
		$('.car_search_results form.propositions .search_result_bottom .summ span').text(currentPrice);
	});
});